package au.com.handsunited.model;

import org.hibernate.search.annotations.Indexed;
import org.joda.time.DateTime;
import org.slf4j.Logger;
import org.slf4j.LoggerFactory;

import au.com.handsunited.jodawrapper.JodaLocalDateWrapper;

/**
 *
 * @author arunda
 */
@Indexed
public class Project extends BaseEntity {

	private JodaLocalDateWrapper startDate;
	private JodaLocalDateWrapper endDate;
	private Boolean onGoing; // Project runs all year and not between two dates

	private Boolean recommendedForGroups;
	private Boolean recommendedForYouth;
	private Boolean recommendedForKids;
	private Boolean recommendedForOldies;
	private Boolean recommendedForLadies;
	private int minimumAgeRequired;
	private int numberRequired;
	private int hourlyCommitment;

	/*
	 * per day, per week, per fortnight, per month, per event
	 */
	private String commitmentType;


	private static Logger logger = LoggerFactory.getLogger(Project.class);

	/**
	 *
	 */
	public Project() {
		super();
		startDate = new JodaLocalDateWrapper();
		endDate = new JodaLocalDateWrapper();
	}


	/**
	 * @see au.com.handsunited.model.Project#getNumberRequired()
	 */
	public int getNumberRequired() {
		return numberRequired;
	}

	/**
	 * @see au.com.handsunited.model.Project#getStartDate()
	 */
	public JodaLocalDateWrapper getStartDate() {
		return startDate;
	}

	/**
	 * @see au.com.handsunited.model.Project#setStartDate(DateTime)
	 */
	public void setStartDate(JodaLocalDateWrapper startDate) {
		this.startDate = startDate;
	}

	/**
	 * @see au.com.handsunited.model.Project#getEndDate()
	 */
	public JodaLocalDateWrapper getEndDate() {
		return endDate;
	}

	/**
	 * @see au.com.handsunited.model.Project#setEndDate(DateTime)
	 */
	public void setEndDate(JodaLocalDateWrapper endDate) {
		this.endDate = endDate;
	}

	/**
	 * @see au.com.handsunited.model.Project#isOnGoing()
	 */
	public boolean isOnGoing() {
		return onGoing;
	}

	/**
	 * @see au.com.handsunited.model.Project#setOnGoing(boolean)
	 */
	public void setOnGoing(boolean onGoing) {
		this.onGoing = onGoing;
	}


	/**
	 * @return the recommendedForGroups
	 */
	public boolean isRecommendedForGroups() {
		return recommendedForGroups;
	}

	/**
	 * @param recommendedForGroups the recommendedForGroups to set
	 */
	public void setRecommendedForGroups(boolean recommendedForGroups) {
		this.recommendedForGroups = recommendedForGroups;
	}

	/**
	 * @return the recommendedForYouth
	 */
	public boolean isRecommendedForYouth() {
		return recommendedForYouth;
	}

	/**
	 * @param recommendedForYouth the recommendedForYouth to set
	 */
	public void setRecommendedForYouth(boolean recommendedForYouth) {
		this.recommendedForYouth = recommendedForYouth;
	}

	/**
	 * @return the recommendedForKids
	 */
	public boolean isRecommendedForKids() {
		return recommendedForKids;
	}

	/**
	 * @param recommendedForKids the recommendedForKids to set
	 */
	public void setRecommendedForKids(boolean recommendedForKids) {
		this.recommendedForKids = recommendedForKids;
	}

	/**
	 * @return the recommendedForOldies
	 */
	public boolean isRecommendedForOldies() {
		return recommendedForOldies;
	}

	/**
	 * @param recommendedForOldies the recommendedForOldies to set
	 */
	public void setRecommendedForOldies(boolean recommendedForOldies) {
		this.recommendedForOldies = recommendedForOldies;
	}

	/**
	 * @return the recommendedForLadies
	 */
	public boolean isRecommendedForLadies() {
		return recommendedForLadies;
	}

	/**
	 * @param recommendedForLadies the recommendedForLadies to set
	 */
	public void setRecommendedForLadies(boolean recommendedForLadies) {
		this.recommendedForLadies = recommendedForLadies;
	}

	/**
	 * @return the minimumAgeRequired
	 */
	public int getMinimumAgeRequired() {
		return minimumAgeRequired;
	}

	/**
	 * @param minimumAgeRequired the minimumAgeRequired to set
	 */
	public void setMinimumAgeRequired(int minimumAgeRequired) {
		this.minimumAgeRequired = minimumAgeRequired;
	}

	/**
	 * @return the hourlyCommitment
	 */
	public int getHourlyCommitment() {
		return hourlyCommitment;
	}

	/**
	 * @param hourlyCommitment the hourlyCommitment to set
	 */
	public void setHourlyCommitment(int hourlyCommitment) {
		this.hourlyCommitment = hourlyCommitment;
	}

	/**
	 * @return the commitmentType
	 */
	public String getCommitmentType() {
		return commitmentType;
	}

	/**
	 * @param commitmentType the commitmentType to set
	 */
	public void setCommitmentType(String commitmentType) {
		this.commitmentType = commitmentType;
	}

	/**
	 * @param numberRequired the numberRequired to set
	 */
	public void setNumberRequired(int numberRequired) {
		this.numberRequired = numberRequired;
	}

	/**
	 * @see au.com.handsunited.model.BaseEntity#isProject()
	 */
	@Override
	public boolean isProject() {
		return true;
	}

	/**
	 * @see au.com.handsunited.model.BaseEntity#getEntityType()
	 */
	@Override
	public String getEntityType() {
		return "project";
	}

}
